# 2.对于列表l=[1,2,3,4,5,6,7]
# 写出下边切片的具体内容,手写后去电脑上对照一下
# l[1:5]    2 3 4 5 
#   l[1:5:2]    2 4 
# l[:5:2]    1 3 5
#   l[::2]    1 3 5 7
l = [1,2,3,4,5,6,7]
print(l[1:5])
print(l[1:5:2])
print(l[:5:2])
print(l[::2])